{%include file="m.index.header.tpl.php"%}
<!--头部 end--> 
<!--主体部分-->
<form action="" method="get">	
<div class="container" style="margin-top:70px;">  
  <div class="row" style="margin-top:10px;">
    <div class="col-sm-12 distance hierarchy" >
      <div class="form-group">
        <label for="" class="col-sm-2  control-label">教师姓名：</label>
        <div class="col-sm-10 ">
		{%if $staff_id !=''%}
		{%$staff_data.staff_name%}
		{%else%}
          <input type="text"  class="form-control " name="staff_name">
		  {%/if%}
        </div>
      </div>
    </div>
    <div class="col-sm-12 distance hierarchy" >
      <div class="form-group">
        <label for="" class="col-sm-2  control-label">开始时间：</label>
        <div class="col-sm-10 ">
          <input type="text" name="from" id="from" class="form-control ">
        </div>
      </div>
    </div>
    <div class="col-sm-12 distance hierarchy2" >
      <div class="form-group">
        <label for="" class="col-sm-2  control-label">结束时间：</label>
        <div class="col-sm-10 ">
          <input type="text" name="to" id="to" class="form-control ">
        </div>
      </div>
    </div>
    <div class="col-xs-12  distance hierarchy2">
      <div class="form-group text-center" style="padding-top:0px;">
		<input type="hidden" name="personnel_type" value="{%$personnel_type%}">
		<input type="hidden" name="a" value="change.list">
        <button type="submit" class="btn btn-success absolutely ">搜索</button>
      </div>
    </div>
  </div>
  </form>
  <div class="row content-top">
    <h5>人事变动记录共 {%$count%} 条</h5>
	{%foreach from=$staff_lists key=key item=value%}
    <table class="table table-striped table-bordered text-center"  id="middles">
      <tr>
        <td>编号</td>
        <td>{%$value.staff_number%}</td>
      </tr>
      <tr>
        <td>姓名</td>
        <td>{%$value.staff_name%}</td>
      </tr>
      <tr>
        <td>变动事项</td>
        <td>{%$value.personnel_variation%}</td>
      </tr>
      <tr>
        <td>日期</td>
        <td>{%$value.start_time%}</td>
      </tr>
      <tr>
        <td>源单位</td>
        <td>{%$value.personnel_from%}</td>
      </tr>
      <tr>
        <td>目的单位</td>
        <td>{%$value.personnel_to%}</td>
      </tr>
      <tr>
        <td>在岗信息</td>
        <td>{%$value.staff_sign%}</td>
      </tr>
      <tr>
        <td>备注</td>
        <td>{%$value.personnel_remark%}</td>
      </tr>
      <tr>
        <td>操作</td>
        <td ><a type="button" class="btn btn-danger  " href="index.php?a=change.add&staff_id={%$value.staff_id%}&personnel_type=1" >修改</a></td>
      </tr>
    </table>
 {%/foreach%}
  </div>
</div>
<!--container  end--> 

<!--主体部分  end--> 
{%include file="m.index.footer.tpl.php"%}
<script>
  $(function() {
    $( "#from" ).datepicker({
      defaultDate: "+1w",
      changeMonth: true,
      changeYear: true,
      numberOfMonths:1,
      onClose: function( selectedDate ) {
        $( "#to" ).datepicker( "option", "minDate", selectedDate );
      }
    });
    $( "#to" ).datepicker({
      defaultDate: "+1w",
      changeMonth: true,
      changeYear: true,
      numberOfMonths:1,
      onClose: function( selectedDate ) {
        $( "#from" ).datepicker( "option", "maxDate", selectedDate );
      }
    });
  });
</script>